<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>模版关联域名管理 HDSysCms</title>
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
<link rel="stylesheet" href="<?php echo getcdnurlhost() ?>/admin/layui/css/layui.css" media="all">
<link rel="stylesheet" href="<?php echo getcdnurlhost() ?>/admin/style/admin.css" media="all">
</head>
<body data="HDSYSCMS 2021本系统受国家版权局保护请勿破解或者二次开发传播">
<div class="layui-fluid">
<div class="layui-row layui-col-space15">
<div class="layui-col-md12">
<div class="layui-card">
<div class="layui-card-header">模版关联域名管理</div>
<div class="layui-card-body">
<div class="layui-btn-container1 rows">
<div class="layui-bins">
<button class="layui-btn layui-btn-sm bin-add" lay-event="act_1"><i class="layui-icon layui-icon-add-circle-fine"></i>添加模版关联域名</button>
</div>
<div class="layui-soso">
<input onkeydown="if(event.keyCode==13){  document.getElementById('binsoso').click(); }" type="text" name="soso" id="soso" placeholder="请输入">
<button id="binsoso" lay-submit lay-filter="LAY-user-front-search" class="layui-btn layui-btn-sm layuiadmin-btn-useradmin"><i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>搜索</button>
</div>
<style></style>
</div>
<table lay-even lay-skin="nob" lay-size="lg" class="layui-hide" id="test-table-toolbar" lay-filter="test-table-toolbar"></table>
<script type="text/html" id="test-table-toolbar-barDemo"><a class="layui-btn layui-btn-xs" lay-event="del"><i class="layui-icon">&#xe640;</i>删除</a></script>
</div>
</div>
</div>
</div>
</div>
<?php adminechohtnl(); ?>
<div id="foot">Copyright © 2019-2023 <a href="https://www.HDSysCms.Com?pro" target="_blank">HDSysCms <?php echo HDSYS_VERSION; ?></a> <br>
All Rights Reserved </div>
<script src="<?php echo getcdnurlhost() ?>/admin/layui/layui.js"></script>
<script>layui.config({base: '<?php echo getcdnurlhost() ?>/admin/'}).extend({index: 'lib/index'}).use(['jquery', 'index', 'table', 'layer'], function() {var admin=layui.admin,$=layui.$,table=layui.table;table.render({elem: '#test-table-toolbar',url: 'index.php?m=<?php echo set_get('m'); ?>&c=<?php echo set_get('c'); ?>&a=<?php echo set_get('a'); ?>_ajax&json=get&soso_ok=1',toolbar: false  ,skin: 'line',title: '模版关联域名管理',height: 'full-210',groups: 1  ,first: false  ,last: false  ,cols: [[{fixed: 'right',title: 'ID',toolbar: '#test-table-toolbar-barDemo',width: 115}, {field: 'template',width: 300,title: '模版目录',}, {field: 'name',width: 250,title: '模版名称',}, {field: 'domain',title: '绑定域名'}]],page: false});table.on('edit(test-table-toolbar)', function(obj) {var value=obj.value  ,data=obj.data  ,field=obj.field;$.ajax({type: "post",url: 'index.php?m=manage&c=<?php echo set_get("c") ?>&a=edit_ajax',data: 'id=' + data.id + "&field=" + value,dataType: "json",success: function(ret) {layer.msg(ret.msg);table.reload('test-table-toolbar', {page: {curr: 1}});},error: function(e, t) {layer.alert('接口请求返还异常');}})});table.on('tool(test-table-toolbar)', function(obj) {var data=obj.data;if (obj.event==='del') {layer.confirm('你确定删除模版关联域名吗？', {btn: ['确定', '取消']}, function() {$.ajax({type: "post",url: 'index.php?m=manage&c=<?php echo set_get("c") ?>&a=del_ajax',data: 'id=' + data.id,dataType: "json",success: function(ret) {layer.msg(ret.msg);table.reload('test-table-toolbar', {page: {curr: 1}});},error: function(e, t) {layer.alert('接口请求返还异常');}})}, function() {});} else if (obj.event==='edit') {layer.open({type: 2,area: ['600px', '290px'],fixed: false,maxmin: true,content: 'index.php?m=manage&c=<?php echo set_get('c') ?>&a=password&id=' + data.id});}});$('.layuiadmin-btn-useradmin').on('click', function() {table.reload('test-table-toolbar', {page: {curr: 1},where: {soso: $("#soso").val()}});});$('.bin-add').on('click', function() {layer.open({type: 2,title: '添加模版关联域名',area: ['600px', '460px'],fixed: false,maxmin: true,content: 'index.php?m=manage&c=<?php echo set_get('c') ?>&a=add'});});});</script>
</body>
</html>